package VN.EDU.IMIC.DEVELOPER.TRINHCAOSANG.Exam01.Bai1.Bai1;

/**
 * Created by Sang on 07/03/2016.
 */
public class RectangleEntity implements IGeometricObject {
    private double shortSide;
    private double longSide;

    public double getShortSide() {
        return shortSide;
    }

    public void setShortSide(double shortSide) {
        this.shortSide = shortSide;
    }

    public double getLongSide() {
        return longSide;
    }

    public void setLongSide(double longSide) {
        this.longSide = longSide;
    }

    @Override
    public double getArea(Object object) {
        return shortSide * longSide;
    }

    @Override
    public double getPerimeter(Object object) {
        return (shortSide + longSide) * 2;
    }
}
